import { createApp } from 'vue';
import App from './App.vue';
import router from './router';
import pinia from './store';
import qiankunSubStart from './qiankunSub';
// 全量引入
import ElementPlus from 'element-plus';
import 'element-plus/dist/index.css';
import 'element-plus/theme-chalk/dark/css-vars.css';
import * as ElementPlusIconsVue from '@element-plus/icons-vue';
// 自定义的样式
import '@/styles/index.scss';

// qiankun微应用
qiankunSubStart(() => {

  const app = createApp(App);

  for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
  }

  app.use(ElementPlus);
  //安装仓库
  app.use(pinia as any)
  app.use(router);

  return app;
}, '#app')
